<!DOCTYPE html>
<!--[if IE 8]> <html lang="en" class="ie8 no-js"> <![endif]-->
<!--[if IE 9]> <html lang="en" class="ie9 no-js"> <![endif]-->
<!--[if !IE]><!-->
<html lang="en" class="no-js">
<!--<![endif]-->

<head>
<meta charset="utf-8">
<title>SMM撮合系统</title>
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta content="width=device-width, initial-scale=1" name="viewport">
<meta content="" name="description">
<meta content="" name="author">
<script>BASE_URL ='${request.getContextPath()}'</script>
<link href="${request.getContextPath()}/Public/assets/admin/css/css.css" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/assets/global/plugins/font-awesome/css/font-awesome.min.css" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/assets/global/plugins/simple-line-icons/simple-line-icons.min.css" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/assets/global/plugins/bootstrap/css/bootstrap.min.css" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/assets/global/plugins/uniform/css/uniform.default.css" rel="stylesheet" type="text/css">

<link href="${request.getContextPath()}/Public/assets/global/css/components-rounded.css" id="style_components" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/assets/global/css/plugins.css" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/assets/admin/css/layout.css" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/assets/admin/css/themes/default.css" rel="stylesheet" type="text/css" id="style_color">
<link href="${request.getContextPath()}/Public/assets/admin/css/custom.css" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/assets/global/plugins/bootstrap-datepicker/css/bootstrap-datepicker.min.css" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/css/customerDetail.css" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/assets/admin/css/common.css" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/assets/global/css/kkpager.css" rel="stylesheet" type="text/css">
<link rel="shortcut icon" href="${request.getContextPath()}/Public/favicon.ico">
<link href="${request.getContextPath()}/Public/css/client.css" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/css/customerDetail.css" rel="stylesheet" type="text/css">
<script type="text/javascript" src="${request.getContextPath()}/Public/My97DatePicker/WdatePicker.js"></script>
</head>

<body class="page-header-top-fixed">
	<!--头部信息结束 -->
	<div class="page-header">
		<!--头部开始-->
		<#include "/include/top.html" />
		<!-- 头部信息结束 -->
		<!-- 头部菜单开始 -->
		<#include "/include/top_menu.html" />
		<!-- 头部菜单结束 -->
	</div>
	<!-- END HEADER -->
 <div class="modal-header">
	<h4 class="modal-title" style="font-weight:bold; text-align:center;">同步数据</h4>
</div>
		<!-- BEGIN PAGE CONTAINER -->
<div class="modal-body">
	<div class="portlet-body form">
		<div class="form-body">
			<div class="form-group form-md-radios" >
			   		<#if Session['userInfo']['id'] == 14 || Session['userInfo']['id'] == 59>
				    <table class="ttTbl" style="width:70%; margin:0 auto;">
				    	<tbody>
				    		<tr>
				    			<td><a onclick="synchroArea()" href="javascript:void(0);">地区（ch_areas）</a></td>
				    			<td><a onclick="synchroProduct()" href="javascript:void(0);">产品（ch_product）</a></td>
				    		</tr>
				    		<tr>
				    			<td><a onclick="synchroCommodity()" href="javascript:void(0);">商品（ch_commodity）</a></td>
				    			<td><a onclick="synchroCommodityAttr()" href="javascript:void(0);">商品属性（ch_commodity_attr）</a></td>
				    		</tr>
				    		<tr>
				    			<td><a onclick="synchroItemAttr()" href="javascript:void(0);">品目属性（ch_item_attr）</a></td>
				    			<td>&nbsp;</td>
				    			<!--<td><a onclick="synchroWare()" href="javascript:void(0);">仓库（ch_warehouse）</a></td>-->
				    		</tr>
				    	</tbody>
				    </table>
				    </#if>
				 </div>
		  </div>
	</div>
</div>
<!-- END PAGE CONTAINER -->

<!--[if lt IE 9]>
<script src="${request.getContextPath()}/Public/assets/global/plugins/respond.min.js"></script>
<script src="${request.getContextPath()}/Public/assets/global/plugins/excanvas.min.js"></script> 
<![endif]-->
<script src="${request.getContextPath()}/Public/assets/global/plugins/jquery.min.js" type="text/javascript"></script>
<script src="${request.getContextPath()}/Public/My97DatePicker/WdatePicker.js" type="text/javascript"></script>
<script src="${request.getContextPath()}/Public/assets/global/plugins/jquery-migrate.min.js" type="text/javascript"></script>
<script src="${request.getContextPath()}/Public/assets/global/plugins/jquery-ui/jquery-ui.min.js" type="text/javascript"></script>
<script src="${request.getContextPath()}/Public/assets/global/plugins/bootstrap/js/bootstrap.min.js" type="text/javascript"></script>
<script src="${request.getContextPath()}/Public/assets/global/plugins/bootstrap-hover-dropdown/bootstrap-hover-dropdown.min.js" type="text/javascript"></script>
<script src="${request.getContextPath()}/Public/assets/global/plugins/jquery-slimscroll/jquery.slimscroll.min.js" type="text/javascript"></script>
<script src="${request.getContextPath()}/Public/assets/global/plugins/jquery.blockui.min.js" type="text/javascript"></script>
<script src="${request.getContextPath()}/Public/assets/global/plugins/jquery.cokie.min.js" type="text/javascript"></script>
<script src="${request.getContextPath()}/Public/assets/global/plugins/uniform/jquery.uniform.min.js" type="text/javascript"></script>
<script src="${request.getContextPath()}/Public/assets/global/plugins/jquery-notific8/jquery.notific8.min.js"></script>
<script src="${request.getContextPath()}/Public/assets/global/plugins/bootstrap-datepicker/js/bootstrap-datepicker.js" type="text/javascript"></script>
<script src="${request.getContextPath()}/Public/assets/global/scripts/metronic.js" type="text/javascript"></script>
<script src="${request.getContextPath()}/Public/assets/admin/scripts/layout.js" type="text/javascript"></script>
<script src="${request.getContextPath()}/Public/assets/global/plugins/kkpager.min.js" type="text/javascript"></script>
<script src="${request.getContextPath()}/Public/assets/admin/scripts/commonUtils.js" type="text/javascript"></script>

<script>
	jQuery(document).ready(function() {
		Metronic.init(); // init metronic core componets
		Layout.init(); // init layout
	});

	//同步地区表
	function synchroArea(){
		if(!confirm("确认同步地区表？")){
			return;
		}
		$.ajax({
			url : "${request.getContextPath()}/mallTo/synchroArea.do",
			type : "post",
			dataType:"json",
			async: false,
			success : function(result) {
				alert(result.message);
			  }
		});
	}
	//同步产品表
	function synchroProduct(){
		if(!confirm("确认同步产品表？")){
			return;
		}
		$.ajax({
			url : "${request.getContextPath()}/mallTo/synchroProduct.do",
			type : "post",
			dataType:"json",
			async: false,
			success : function(result) {
				alert(result.message);
			  }
		});
	}
	//同步商品表
	function synchroCommodity(){
		if(!confirm("确认同步商品表？")){
			return;
		}
		$.ajax({
			url : "${request.getContextPath()}/mallTo/synchroCommodity.do",
			type : "post",
			dataType:"json",
			async: false,
			success : function(result) {
				alert(result.message);
			  }
		});
	}
	//同步商品属性表
	function synchroCommodityAttr(){
		if(!confirm("确认同步商品属性表？")){
			return;
		}
		$.ajax({
			url : "${request.getContextPath()}/mallTo/synchroCommodityAttr.do",
			type : "post",
			dataType:"json",
			async: false,
			success : function(result) {
				alert(result.message);
			  }
		});
	}
	//同步品目属性表
	function synchroItemAttr(){
		if(!confirm("确认同步品目属性表？")){
			return;
		}
		$.ajax({
			url : "${request.getContextPath()}/mallTo/synchroItemAttr.do",
			type : "post",
			dataType:"json",
			async: false,
			success : function(result) {
				alert(result.message);
			  }
		});
	}
	
	//同步仓库表
	function synchroWare(){
		if(!confirm("确认同步仓库表？")){
			return;
		}
		$.ajax({
			url : "${request.getContextPath()}/mallTo/synchroWare.do",
			type : "post",
			dataType:"json",
			async: false,
			success : function(result) {
				alert(result.message);
			 }
		});
	 }
</script>
</body>
</html>